#include "Bullet3Dynamics/ConstraintSolver/b3SolverBody.h"
#ifdef __cplusplus
extern "C" {
#endif
b3SolverBody* bullet_Newb3SolverBody(){
	b3SolverBody* wrap_out = new b3SolverBody();
	return wrap_out;
}

void bullet_b3SolverBody_applyImpulse(b3SolverBody* c_this,b3Vector3* linearComponent,b3Vector3* angularComponent,float impulseMagnitude){
	b3Vector3 const& c_arg_linearComponent=(b3Vector3 const&)(*linearComponent);
	b3Vector3 const& c_arg_angularComponent=(b3Vector3 const&)(*angularComponent);
	b3Scalar const c_arg_impulseMagnitude=impulseMagnitude;
	c_this->applyImpulse(c_arg_linearComponent,c_arg_angularComponent,c_arg_impulseMagnitude);
}

void bullet_b3SolverBody_getAngularVelocity(b3SolverBody* c_this,b3Vector3* angVel){
	b3Vector3& c_arg_angVel=(b3Vector3&)(*angVel);
	c_this->getAngularVelocity(c_arg_angVel);
}

b3Vector3* bullet_b3SolverBody_getDeltaAngularVelocity(b3SolverBody* c_this){
	b3Vector3 const& c_out = c_this->getDeltaAngularVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

b3Vector3* bullet_b3SolverBody_getDeltaLinearVelocity(b3SolverBody* c_this){
	b3Vector3 const& c_out = c_this->getDeltaLinearVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_angularFactor(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_angularFactor);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_angularVelocity(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_angularVelocity);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_deltaAngularVelocity(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_deltaAngularVelocity);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_deltaLinearVelocity(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_deltaLinearVelocity);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_invMass(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_invMass);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_linearFactor(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_linearFactor);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_linearVelocity(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_linearVelocity);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_pushVelocity(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_pushVelocity);
}

b3Vector3* bullet_b3SolverBody_GetFieldOfM_turnVelocity(b3SolverBody* c_this){
	return (b3Vector3*)(&c_this->m_turnVelocity);
}

b3Transform* bullet_b3SolverBody_GetFieldOfM_worldTransform(b3SolverBody* c_this){
	return (b3Transform*)(&c_this->m_worldTransform);
}

int** bullet_b3SolverBody_GetFieldOfPadding(b3SolverBody* c_this){
	return (int**)(&c_this->padding);
}

b3Vector3* bullet_b3SolverBody_getPushVelocity(b3SolverBody* c_this){
	b3Vector3 const& c_out = c_this->getPushVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

b3Vector3* bullet_b3SolverBody_getTurnVelocity(b3SolverBody* c_this){
	b3Vector3 const& c_out = c_this->getTurnVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

void bullet_b3SolverBody_getVelocityInLocalPointObsolete(b3SolverBody* c_this,b3Vector3* rel_pos,b3Vector3* velocity){
	b3Vector3 const& c_arg_rel_pos=(b3Vector3 const&)(*rel_pos);
	b3Vector3& c_arg_velocity=(b3Vector3&)(*velocity);
	c_this->getVelocityInLocalPointObsolete(c_arg_rel_pos,c_arg_velocity);
}

b3Transform* bullet_b3SolverBody_getWorldTransform(b3SolverBody* c_this){
	b3Transform const& c_out = c_this->getWorldTransform();
	b3Transform* wrap_out = (b3Transform*)(&c_out);
	return wrap_out;
}

void bullet_b3SolverBody_internalApplyImpulse(b3SolverBody* c_this,b3Vector3* linearComponent,b3Vector3* angularComponent,float impulseMagnitude){
	b3Vector3 const& c_arg_linearComponent=(b3Vector3 const&)(*linearComponent);
	b3Vector3 const& c_arg_angularComponent=(b3Vector3 const&)(*angularComponent);
	b3Scalar const c_arg_impulseMagnitude=impulseMagnitude;
	c_this->internalApplyImpulse(c_arg_linearComponent,c_arg_angularComponent,c_arg_impulseMagnitude);
}

void bullet_b3SolverBody_internalApplyPushImpulse(b3SolverBody* c_this,b3Vector3* linearComponent,b3Vector3* angularComponent,float impulseMagnitude){
	b3Vector3 const& c_arg_linearComponent=(b3Vector3 const&)(*linearComponent);
	b3Vector3 const& c_arg_angularComponent=(b3Vector3 const&)(*angularComponent);
	b3Scalar c_arg_impulseMagnitude=impulseMagnitude;
	c_this->internalApplyPushImpulse(c_arg_linearComponent,c_arg_angularComponent,c_arg_impulseMagnitude);
}

b3Vector3* bullet_b3SolverBody_internalGetAngularFactor(b3SolverBody* c_this){
	b3Vector3 const& c_out = c_this->internalGetAngularFactor();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

void bullet_b3SolverBody_internalGetAngularVelocity(b3SolverBody* c_this,b3Vector3* angVel){
	b3Vector3& c_arg_angVel=(b3Vector3&)(*angVel);
	c_this->internalGetAngularVelocity(c_arg_angVel);
}

b3Vector3* bullet_b3SolverBody_internalGetDeltaAngularVelocity(b3SolverBody* c_this){
	b3Vector3& c_out = c_this->internalGetDeltaAngularVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

b3Vector3* bullet_b3SolverBody_internalGetDeltaLinearVelocity(b3SolverBody* c_this){
	b3Vector3& c_out = c_this->internalGetDeltaLinearVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

b3Vector3* bullet_b3SolverBody_internalGetInvMass(b3SolverBody* c_this){
	b3Vector3 const& c_out = c_this->internalGetInvMass();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

b3Vector3* bullet_b3SolverBody_internalGetPushVelocity(b3SolverBody* c_this){
	b3Vector3& c_out = c_this->internalGetPushVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

b3Vector3* bullet_b3SolverBody_internalGetTurnVelocity(b3SolverBody* c_this){
	b3Vector3& c_out = c_this->internalGetTurnVelocity();
	b3Vector3* wrap_out = (b3Vector3*)(&c_out);
	return wrap_out;
}

void bullet_b3SolverBody_internalGetVelocityInLocalPointObsolete(b3SolverBody* c_this,b3Vector3* rel_pos,b3Vector3* velocity){
	b3Vector3 const& c_arg_rel_pos=(b3Vector3 const&)(*rel_pos);
	b3Vector3& c_arg_velocity=(b3Vector3&)(*velocity);
	c_this->internalGetVelocityInLocalPointObsolete(c_arg_rel_pos,c_arg_velocity);
}

void bullet_b3SolverBody_internalSetInvMass(b3SolverBody* c_this,b3Vector3* invMass){
	b3Vector3 const& c_arg_invMass=(b3Vector3 const&)(*invMass);
	c_this->internalSetInvMass(c_arg_invMass);
}

void bullet_b3SolverBody_setWorldTransform(b3SolverBody* c_this,b3Transform* worldTransform){
	b3Transform const& c_arg_worldTransform=(b3Transform const&)(*worldTransform);
	c_this->setWorldTransform(c_arg_worldTransform);
}

void bullet_b3SolverBody_writebackVelocity(b3SolverBody* c_this){
	c_this->writebackVelocity();
}

void bullet_b3SolverBody_writebackVelocityAndTransform(b3SolverBody* c_this,float timeStep,float splitImpulseTurnErp){
	b3Scalar c_arg_timeStep=timeStep;
	b3Scalar c_arg_splitImpulseTurnErp=splitImpulseTurnErp;
	c_this->writebackVelocityAndTransform(c_arg_timeStep,c_arg_splitImpulseTurnErp);
}

#ifdef __cplusplus
}
#endif
